{% extends "base.html" %}
{% block content %}

<p class="nav">
{% if back_date %}
    <a href="{{ url_for('dashboard', year=back_date.year, month=back_date.month, day=back_date.day) }}">
        &laquo; {{ back_date.strftime("%m/%d/%Y") }}
    </a>

    /

    {{ date.strftime("%m/%d/%Y") }}
{% endif %}
{% if forward_date %}
    /
    <a href="{{ url_for('dashboard', year=forward_date.year, month=forward_date.month, day=forward_date.day) }}">
        {{ forward_date.strftime("%m/%d/%Y") }} &raquo;
    </a>
{% else %}
    / <a href="http://www.google.com/search?q=futurama&um=1&ie=UTF-8&tbm=isch&source=og&sa=N&hl=en&tab=wi&biw=1479&bih=897&uss=1">The year 3000</a> &raquo;
{% endif %}
</p>

<!-- Reference date: {{ date }} -->

{% for m in metrics %}
<div class="metric">
  {% for name, value in m.items() %}
      <h2>{{ name }}</h2>
      <p class="value">{{ value }}</p>
  {% endfor %}
</div>
{% endfor %}

<div id="wip_data">

{% import "card_macros.html" as card_macros %}
{{ card_macros.card_table(wip_cards, request, caption="Building") }}

{% set section_title = "Planning / %s" % (backlog_cards|length, ) %}
{{ card_macros.card_table(backlog_cards, request, caption=section_title, show_state=False, show_priority=False, show_cycle=False) }}

</div>

{% endblock content %}
